<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Spatie\Permission\Models\Permission as BasePermission;
use EloquentFilter\Filterable;
use App\Models\Traits\Admin\ActionButtonTrait;

class Permission extends BasePermission
{
    use Filterable, ActionButtonTrait;

    protected $appends = ['actionButton'];

    protected $actions = ['edit','delete'];

    protected $actionUri = 'permissions';


    public function parent()
    {
    	return $this->belongsTo(self::class, 'parent_id', 'id');
    }
}
